/*
 * @User 		@Company 	@Date
 * marcusbui	VNNET24  	Jun 19, 2011
 */
package tsb.com.html5.controller.common;

import java.util.HashMap;

import javax.annotation.PostConstruct;
import javax.annotation.PreDestroy;
import javax.annotation.Resource;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.springframework.stereotype.Controller;
import org.springframework.web.servlet.ModelAndView;

import tsb.com.html5.common.param.GetApplicationCachedDataParam;
import tsb.com.html5.common.service.ICommonService;
import tsb.com.html5.controller.base.BaseController;

// TODO: Auto-generated Javadoc
/**
 * The Class InitController.
 */
@Controller
public class InitController extends BaseController{

	/** The common service. */
	@Resource(name="CommonService")
	private ICommonService commonService;
	
	/**
	 * Inits the.
	 *
	 * @throws Exception the exception
	 */
	@PostConstruct
	public void init() throws Exception{
		logger.debug("<<<<<<< InitController init >>>>>");
//		GetApplicationCachedDataParam param = new GetApplicationCachedDataParam();
		try {
			
//			HashMap<String, Object> applicationData = commonService.getApplicationCachedData(param);
			this.cacheController.loadApplicationCache();
			
		} catch (Exception e) {
			e.printStackTrace();
			throw e;
		}
	}
	
	/**
	 * Destroy.
	 */
	@PreDestroy
	public void destroy(){
		logger.debug("<<<<<<< InitController destroy >>>>>");
	}

}
